package org.jeecg.modules.qyxx.controller;

import java.time.Year;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
import java.io.IOException;
import java.io.UnsupportedEncodingException;
import java.net.URLDecoder;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.jeecg.common.api.vo.Result;
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.common.aspect.annotation.AutoLog;
import org.jeecg.common.util.oConvertUtils;
import org.jeecg.modules.basesource.entity.SbCwbbBw;
import org.jeecg.modules.basesource.service.ISbCwbbBwService;
import java.util.Date;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import lombok.extern.slf4j.Slf4j;
import org.jeecg.common.system.base.controller.JeecgController;
import org.jeecgframework.poi.excel.ExcelImportUtil;
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
import org.jeecgframework.poi.excel.entity.ExportParams;
import org.jeecgframework.poi.excel.entity.ImportParams;
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.MultipartHttpServletRequest;
import org.springframework.web.servlet.ModelAndView;
import com.alibaba.fastjson.JSON;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;

 /**
 * @Description: 财务报表报文
 * @Author: jeecg-boot
 * @Date:   2022-03-03
 * @Version: V1.0
 */
@Slf4j
@Api(tags="财务报表报文")
@RestController
@RequestMapping("/qyxx/cwbb")
public class CwbbBwController extends JeecgController<SbCwbbBw, ISbCwbbBwService> {
	@Autowired
	private ISbCwbbBwService sbCwbbBwService;
	
	/**
	 * 按年财务报表季报报文
	 *
	 * @param req
	 * @return
	 */
	@AutoLog(value = "按年财务报表季报报文")
	@ApiOperation(value="按年财务报表季报报文", notes="按年财务报表季报报文")
	@GetMapping(value = "/querySeasonByYear")
	public Result<List<SbCwbbBw>> querySeasonsByYear(@RequestParam String tynsrsbh, @RequestParam String year, HttpServletRequest req) {
		List<SbCwbbBw> cwbbList = sbCwbbBwService.getByYear(tynsrsbh, year);
		return Result.OK(cwbbList);
	}

}
